using System;
using System.ComponentModel;
using System.Diagnostics;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;
using System.Windows.Shapes;
using System.Collections.ObjectModel;

namespace RssReader
{
    public class FeedViewModel : INotifyPropertyChanged
    {
        public FeedViewModel()
        {
            Items = new ObservableCollection<FeedItemViewModel>();
        }
        private string _feedName;
        /// <summary>
        /// Sample ViewModel property; this property is used in the view to display its value using a Binding.
        /// </summary>
        /// <returns></returns>
        public string FeedName
        {
            get
            {
                return _feedName;
            }
            set
            {
                _feedName = value;
                NotifyPropertyChanged("FeedName");
            }
        }

        private string _feedUrl;
        public string FeedUrl
        {
            get
            {
                return _feedUrl;
            }
            set
            {
                _feedUrl = value;
                NotifyPropertyChanged("FeedUrl");
            }
        }

       
                
        

        public ObservableCollection<FeedItemViewModel> Items { get; set; }

        public event PropertyChangedEventHandler PropertyChanged;
        private void NotifyPropertyChanged(String propertyName)
        {
            if (null != PropertyChanged)
            {
                PropertyChanged(this, new PropertyChangedEventArgs(propertyName));
            }
        }
    }
}